﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Windows.Forms;


namespace TICsiraap
{
    public partial class CambiarClave : System.Web.UI.Page
    {
        Registro.ControladorCambiarClave ctlCmbClave = new Registro.ControladorCambiarClave();
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void btnAceptar_Click(object sender, EventArgs e)
        {
            if (txtNuevaClave.Text != txtConfirmar.Text)
            {
                Registro.mensaje.Show("Las claves no coinciden");
                //Response.Write("<script language='JavaScript'>window.alert('Las claves no coinciden')</script>");
            }
            else
                ctlCmbClave.verificarCambiarClave(txtNumeroEmpleado.Text, txtActual.Text, txtNuevaClave.Text);
        }

        protected void btnCancelar_Click(object sender, EventArgs e)
        {
            Response.Redirect("~/login.aspx");
        }
    }
}